<div class="maindiv">
    <div class="centerdiv">
        <div class="dropdown">

            <div class="options">

                <button color="primary" mat-fab aria-label matTooltip="UPDATE">

                    <mat-icon (click)="getServices()">update</mat-icon>
                </button>


                <mat-form-field class="filter" >

                    <mat-select placeholder="Edgewise Filter" [(ngModel)]="selectedNode"
                        (ngModelChange)="onNodeSelection()">
                        <mat-option *ngFor="let node of nodesArray" [value]="node.value">
                            {{ node.viewValue }}
                        </mat-option>
                    </mat-select>

                </mat-form-field>
            </div>
        </div>

        <div class="tablepage">
            <div>
                <mat-form-field class="filter">
                    <input matInput (keyup)="serviceFilter($event.target.value)" placeholder="Filter">
                </mat-form-field>
            </div>

            <div class="podtable">

                <table mat-table [dataSource]="serviceDataSource">

                    <ng-container matColumnDef="serviceName">
                        <th mat-header-cell *matHeaderCellDef> Name </th>
                        <td mat-cell *matCellDef="let eliot"> {{eliot.serviceName}} </td>
                    </ng-container>

                    <ng-container matColumnDef="serviceType">
                        <th mat-header-cell *matHeaderCellDef> Type </th>
                        <td mat-cell *matCellDef="let eliot"> {{eliot.serviceType}} </td>
                    </ng-container>

                    <ng-container matColumnDef="clusterIp">
                        <th mat-header-cell *matHeaderCellDef> Cluster IP </th>
                        <td mat-cell *matCellDef="let eliot"> {{eliot.clusterIp}} </td>
                    </ng-container>

                    <ng-container matColumnDef="externalIp">
                        <th mat-header-cell *matHeaderCellDef> External IP </th>
                        <td mat-cell *matCellDef="let eliot"> {{eliot.externalIp}} </td>
                    </ng-container>

                    <ng-container matColumnDef="ports">
                        <th mat-header-cell *matHeaderCellDef> Ports </th>
                        <td mat-cell *matCellDef="let eliot"> {{eliot.ports}} </td>
                    </ng-container>

                    <ng-container matColumnDef="age">
                        <th mat-header-cell *matHeaderCellDef> Age </th>
                        <td mat-cell *matCellDef="let eliot"> {{eliot.age}} </td>
                    </ng-container>

                    <ng-container matColumnDef="selector">
                        <th mat-header-cell *matHeaderCellDef> Selector </th>
                        <td mat-cell *matCellDef="let eliot"> {{eliot.selector}} </td>
                    </ng-container>


                    <tr mat-header-row *matHeaderRowDef="serviceColumns"></tr>
                    <tr mat-row *matRowDef="let row; columns: serviceColumns;"></tr>
                </table>

                <mat-paginator [pageSizeOptions]="[5, 10, 20]" showFirstLastButtons></mat-paginator>

        </div>
    </div>

</div>